package com.moji.controller.web;


import cn.hutool.http.server.HttpServerRequest;
import com.moji.common.base.ApiResult;
import com.moji.entity.MjOpinion;
import com.moji.entity.MjStatistics;
import com.moji.service.MjOpinionService;
import com.moji.service.MjStatisticsService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;

/**
 * <p>
 * 数据统计表 前端控制器
 * </p>
 *
 * @author ccl
 * @since 2024-11-06
 */
@RestController
@RequestMapping("web/mjStatistics")
@Api(tags = "数据统计", value = "数据统计")
public class MjStatisticsController {

    @Resource
    private MjStatisticsService mjStatisticsService;

    @PostMapping("/add")
    @ApiOperation(value = "新增",response = Boolean.class)
    public ApiResult add(@Validated @RequestBody MjStatistics mjStatistics, HttpServletRequest request){
        return ApiResult.ok(mjStatisticsService.add(mjStatistics,request));
    }
}

